﻿using System;
using System.Collections.Generic;
using System.Text;
using ITDCSYSModel;

namespace ITDCGate
{
    public class DBGate
    {
        public static string GetLineId(string lineName)
        {
            string result = string.Empty;

            ITDCSYSModel.y_BusLine line = new y_BusLine();
            try
            {
                line = new ITDCSYSBLL.y_BusLine().GetDepartmentIdByLineName(lineName);
            }
            catch (Exception ex)
            {
                throw ex;
            }


            if (line != null)
            {
                result = line.nLineID.ToString();
            }

            return result;
        }

        /// <summary>
        /// 获取所有线路名称
        /// </summary>
        /// <returns></returns>
        public static IList<string> GetAllLineName()
        {
            IList<string> result = new List<string>();

            result = new ITDCSYSBLL.y_BusLine().GetAllLineName();

            return result;
        }
    }
}
